<?php /* Smarty version 2.6.16, created on 2012-03-20 20:14:48
         compiled from my_video_update.tpl */ ?>
<?php require_once(SMARTY_CORE_DIR . 'core.load_plugins.php');
smarty_core_load_plugins(array('plugins' => array(array('function', 'html_options', 'my_video_update.tpl', 246, false),array('modifier', 'count', 'my_video_update.tpl', 270, false),array('modifier', 'inarray', 'my_video_update.tpl', 277, false),)), $this); ?>
<?php echo '
<script language="javascript" src="js/contact_us.js"></script> 
<script language="javascript" type="text/javascript">
var j = jQuery.noConflict();
j(document).ready(function(){
	getPageId(\'';  echo $this->_tpl_vars['Formval']['game_id'];  echo '\',\'';  echo $this->_tpl_vars['Formval']['ladder_id'];  echo '\',\'';  echo $this->_tpl_vars['Formval']['race_id'];  echo '\');
});

function getPageId(type,id,rid,sid)
{	

	j.ajax({
			type:\'POST\',
			url:\'game_info.php\',
			data: \'type=\'+type+\'&id=\'+id+\'&rid=\'+rid,
			dataType:\'json\',
			success:function(jData){
			
				if(jData.flag == 1)
				{
					j(\'#ladder_id_td\').html(jData.html);
					j(\'#race_id_td\').html(jData.html1);
					
				}
			},
			error: function(XMLHttpRequest, textStatus, errorThrown){
				j(".contactus-block").html("Some server error occoured. Please report to system administrator.</div>");
			}
		});
}
function CheckFields()
{
  
  var vid=document.getElementById(\'video_id\').value;
  if(document.getElementById(\'video_title\').value==\'\' ) 
   {
    $(\'#FormErrorMsg\').show();
    $(\'#FormErrorMsg\').html("Please enter a title");
	//$(\'#FormFieldCheckErrorMsg\').fadeOut(2000);
    return false;
   }
  if(document.getElementById(\'game_id\').value==\'\' ) 
   {
    $(\'#FormErrorMsg\').show();
    $(\'#FormErrorMsg\').html("Please select a game");
	//$(\'#FormFieldCheckErrorMsg\').fadeOut(2000);
    return false;
   }
/*   if(document.getElementById(\'race_id\').value==\'\' ) 
   {
    $(\'#FormErrorMsg\').show();
    $(\'#FormErrorMsg\').html("Please select a race");
	//$(\'#FormFieldCheckErrorMsg\').fadeOut(2000);
    return false;
   }
   if(document.getElementById(\'ladder_id\').value==\'\' ) 
   {
    $(\'#FormErrorMsg\').show();
    $(\'#FormErrorMsg\').html("Please select a ladder");
	//$(\'#FormFieldCheckErrorMsg\').fadeOut(2000);
    return false;
   }
*/   var vdo_type = document.getElementById(\'is_video_url\').value;
   if(vid==\'\')
   {
	   if(vdo_type==\'N\')
	   {
		 if(document.getElementById(\'video_doc\').value==\'\' ) 
		   {
			$(\'#FormErrorMsg\').show();
			$(\'#FormErrorMsg\').html("Please upload video");
			//$(\'#FormFieldCheckErrorMsg\').fadeOut(2000);
			return false;
		   }
	   }
		if(vdo_type==\'Y\')
	   {
		 if(document.getElementById(\'video_url\').value==\'\' ) 
		   {
			$(\'#FormErrorMsg\').show();
			$(\'#FormErrorMsg\').html("Please enter youtube url");
			//$(\'#FormFieldCheckErrorMsg\').fadeOut(2000);
			return false;
		   }
	   }
	}   
    if(vid==\'\')
   {
	   if(document.getElementById(\'time_length\').value==\'\' ) 
		 {
			$(\'#FormErrorMsg\').show();
			$(\'#FormErrorMsg\').html("Please enter time length");
			//$(\'#FormFieldCheckErrorMsg\').fadeOut(2000);
			return false;
		 }
   		   
   if(document.getElementById(\'img1\').value==\'\' ) 
   {
		$(\'#FormErrorMsg\').show();
		$(\'#FormErrorMsg\').html("Please upload image");
		//$(\'#FormFieldCheckErrorMsg\').fadeOut(2000);
		return false;
   }
 }
  return true;
 }
 function getChangeGame(id)
{	
	//alert(id);
	j(\'#ladder\').hide();
	j(\'#versus\').hide();
	j(\'#type\').hide();
	j(\'#champion\').hide();
	j(\'#team\').hide();
	j(\'#map\').hide();
	j(\'#mode\').hide();
	j(\'#class\').hide();
	j(\'#ladder_gap\').hide();
	j(\'#versus_gap\').hide();
	j(\'#type_gap\').hide();
	j(\'#champion_gap\').hide();
	j(\'#team_gap\').hide();
	j(\'#map_gap\').hide();
	j(\'#mode_gap\').hide();
	j(\'#class_gap\').hide();
	j(\'#champion_gap\').hide();
	j.ajax({
			url:\'game_details.php?is_vedio=1\',
			data: \'id=\'+id,
			type:\'post\',		
			dataType:\'json\',	
		   success:function(resp){
		   //alert(resp.map);
		   if(resp.ladder==\'Y\')
		   {
		   		j(\'#ladder\').show();
				j(\'#ladder_gap\').show();
			}			
			 if(resp.versus==\'Y\')
			 {
		   		/*j(\'#versus\').css(\'display\',\'block\');
				j(\'#versus\').html(resp.versus_str);*/
				j(\'#versus\').show();
				j(\'#versus_gap\').show();
			}	
			 if(resp.type==\'Y\')
		   	{
				j(\'#type\').show();				
				j(\'#type_gap\').show();
			}	
			 if(resp.champion==\'Y\')
		   	{
				j(\'#champion\').show();
				j(\'#champion_gap\').show();
			}	
			 if(resp.team==\'Y\')
		   	{
				j(\'#team\').show();
				j(\'#team_gap\').show();
			}
			 if(resp.map==\'Y\')
		   	{
				j(\'#map\').show();
				j(\'#map_gap\').show();
			}
			 if(resp.mode==\'Y\')
		   	{
				j(\'#mode\').show();
				j(\'#mode_gap\').show();
			}
			 if(resp.is_class==\'Y\')
		   	{
				j(\'#class\').show();
				j(\'#class_gap\').show();
			}
				}
		});
}  
 function keyCheck(eventObj, obj)
{
    var keyCode
 
    // Check For Browser Type
    if (document.all){
        keyCode=eventObj.keyCode
    }
    else{
        keyCode=eventObj.which
    }
 
    var str=obj.value
 
    if(keyCode==46){
        if (str.indexOf(".")>0){
            return false
        }
    }
 
    if((keyCode<46 || keyCode >57)   &&   (keyCode >31)){ // Allow only integers and decimal points
        return false
    }
    
    return true
}
</script>
'; ?>


 <div class="content">
   		<!-- tab -->
    	<ul class="tabflex">
        	<li><a href="dashboard.php"><span>Dashboard</span></a></li>
            <li><a href="inbox.php"><span>Message</span></a></li>
			<li><a href="profile.php"><span>Profile</span></a></li>
			<?php if ($this->_tpl_vars['is_coach'] == '1'): ?><li><a href="coach_game.php"><span>Coach</span></a></li><?php endif; ?>
			<?php if ($this->_tpl_vars['is_partner'] == '1'): ?><li><a href="training_partner_game.php"><span>Training Partner</span></a></li><?php endif; ?>
			<?php if ($this->_tpl_vars['is_coach'] == '1'): ?><li><a href="add_lesson.php"><span>Lessons</span></a></li><?php endif; ?>
			<?php if ($this->_tpl_vars['is_coach'] == '0'): ?><li><a href="my_lesson.php"><span>Lessons</span></a></li><?php endif; ?>
			<li><a href="upload_videos.php" class="active"><span>Videos</span></a></li>
			<?php if ($this->_tpl_vars['is_coach'] == '1'): ?><li><a href="my_review.php"><span>Reviews</span></a></li><?php endif; ?>
			<?php if ($this->_tpl_vars['is_coach'] == '0'): ?><li><a href="my_video_review.php"><span>Reviews</span></a></li><?php endif; ?>
			
          <!--    <li><a href="#"><span>Students</span></a></li>-->
        </ul>
        <!-- tab -->
        <div class="clear"></div>
        <div class="tabular-content"> 
		  <div class="tab_sub">
            	<ul>
                	<li><a href="upload_videos.php" >Upload Videos</a></li>
                    <li><a href="liked_videos.php" class="active">Liked Videos</a></li>
                </ul>
            </div> 
		 <div class="clear"></div>                     
         <div>
      <div class="register">
	   <div id='FormErrorMsg' style="color:red; text-align:center; padding-bottom:10px;"><?php if ($this->_tpl_vars['ermsg'] != ''): ?> <?php echo $this->_tpl_vars['ermsg'];  endif; ?> </div>
      <form name="game" id="game" action="" method="post" enctype="multipart/form-data">
	  <input type="hidden" name="video_id" value="<?php echo $this->_tpl_vars['video_id']; ?>
" id="video_id" />
         <fieldset>
		    <label>Title :</label>
            <input name="video_title" id="video_title" type="text" value="<?php echo $this->_tpl_vars['Formval']['video_title']; ?>
" class="con-req" />
			<p class="clear"></p>
            <label>Select Game :</label>
            <select name="game_id" id="game_id" class="con-req" onchange="getChangeGame(this.value)">
				<option value="">Select</option>
				<?php echo smarty_function_html_options(array('options' => $this->_tpl_vars['GameArr'],'selected' => $this->_tpl_vars['Formval']['game_id']), $this);?>

			</select>
			<p class="clear"></p>
		
			<?php if ($this->_tpl_vars['FabricArr']['is_ladder'] == 'Y'): ?>
		   <div id="ladder_gap" <?php if ($this->_tpl_vars['FabricArr']['is_ladder'] != 'Y'): ?> style='display:none' <?php endif; ?>>
			 <p class="clear"></p>
		  </div>
		  <?php endif; ?>		 
		 <div id="ladder" <?php if ($this->_tpl_vars['FabricArr']['is_ladder'] != 'Y'): ?> style='display:none' <?php endif; ?>>
			<label>Ladder:</label>			
				<select name="ladder_id" id="ladder_id">
					<option value="">Select</option>
					<?php echo smarty_function_html_options(array('options' => $this->_tpl_vars['LadderArr'],'selected' => $this->_tpl_vars['FabricArr']['ladder_id']), $this);?>

				</select>			
		 </div>
		  <div id="versus_gap" <?php if ($this->_tpl_vars['FabricArr']['is_versus'] != 'Y'): ?> style='display:none' <?php endif; ?>>
			<p class="clear"></p>
		  </div>

		
		  <div id="versus"   <?php if ($this->_tpl_vars['FabricArr']['is_versus'] != 'Y'): ?> style='display:none' <?php endif; ?>>
			<label>Versus:</label>
            <p class="clear"></p>			
			<?php if (count($this->_tpl_vars['VersusArr']) != 0): ?>
		 	<?php unset($this->_sections['RowVersus']);
$this->_sections['RowVersus']['name'] = 'RowVersus';
$this->_sections['RowVersus']['loop'] = is_array($_loop=$this->_tpl_vars['VersusArr']) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$this->_sections['RowVersus']['show'] = true;
$this->_sections['RowVersus']['max'] = $this->_sections['RowVersus']['loop'];
$this->_sections['RowVersus']['step'] = 1;
$this->_sections['RowVersus']['start'] = $this->_sections['RowVersus']['step'] > 0 ? 0 : $this->_sections['RowVersus']['loop']-1;
if ($this->_sections['RowVersus']['show']) {
    $this->_sections['RowVersus']['total'] = $this->_sections['RowVersus']['loop'];
    if ($this->_sections['RowVersus']['total'] == 0)
        $this->_sections['RowVersus']['show'] = false;
} else
    $this->_sections['RowVersus']['total'] = 0;
if ($this->_sections['RowVersus']['show']):

            for ($this->_sections['RowVersus']['index'] = $this->_sections['RowVersus']['start'], $this->_sections['RowVersus']['iteration'] = 1;
                 $this->_sections['RowVersus']['iteration'] <= $this->_sections['RowVersus']['total'];
                 $this->_sections['RowVersus']['index'] += $this->_sections['RowVersus']['step'], $this->_sections['RowVersus']['iteration']++):
$this->_sections['RowVersus']['rownum'] = $this->_sections['RowVersus']['iteration'];
$this->_sections['RowVersus']['index_prev'] = $this->_sections['RowVersus']['index'] - $this->_sections['RowVersus']['step'];
$this->_sections['RowVersus']['index_next'] = $this->_sections['RowVersus']['index'] + $this->_sections['RowVersus']['step'];
$this->_sections['RowVersus']['first']      = ($this->_sections['RowVersus']['iteration'] == 1);
$this->_sections['RowVersus']['last']       = ($this->_sections['RowVersus']['iteration'] == $this->_sections['RowVersus']['total']);
?>
			<?php if ($this->_sections['RowVersus']['index']%3 == 0): ?>
			<p class="clear"></p>
			<label>&nbsp;</label>
			<?php endif; ?>
			<input type="checkbox" class="check" name="submited_versus[]"  value="<?php echo $this->_tpl_vars['VersusArr'][$this->_sections['RowVersus']['index']]['versus_id']; ?>
" 
<?php if (((is_array($_tmp=$this->_tpl_vars['VersusArr'][$this->_sections['RowVersus']['index']]['versus_id'])) ? $this->_run_mod_handler('inarray', true, $_tmp, $this->_tpl_vars['submited_versus']) : in_array($_tmp, $this->_tpl_vars['submited_versus']))): ?>checked<?php endif; ?> /> 
			<label class="chkoption"><?php echo $this->_tpl_vars['VersusArr'][$this->_sections['RowVersus']['index']]['versus_title']; ?>
</label>				
			<?php endfor; endif; ?>
			<?php endif; ?>			
		</div>
		
		  <div id="team_gap" <?php if ($this->_tpl_vars['FabricArr']['is_team'] != 'Y'): ?> style='display:none' <?php endif; ?>>
			<p class="clear"></p>
		  </div>
		
		  <div id="team" <?php if ($this->_tpl_vars['FabricArr']['is_team'] != 'Y'): ?> style='display:none' <?php endif; ?>>
			<label>Team:</label> 
			<label>&nbsp;</label>           			
			<?php if (count($this->_tpl_vars['TeamArr']) != 0): ?>
		 	<?php unset($this->_sections['RowTeam']);
$this->_sections['RowTeam']['name'] = 'RowTeam';
$this->_sections['RowTeam']['loop'] = is_array($_loop=$this->_tpl_vars['TeamArr']) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$this->_sections['RowTeam']['show'] = true;
$this->_sections['RowTeam']['max'] = $this->_sections['RowTeam']['loop'];
$this->_sections['RowTeam']['step'] = 1;
$this->_sections['RowTeam']['start'] = $this->_sections['RowTeam']['step'] > 0 ? 0 : $this->_sections['RowTeam']['loop']-1;
if ($this->_sections['RowTeam']['show']) {
    $this->_sections['RowTeam']['total'] = $this->_sections['RowTeam']['loop'];
    if ($this->_sections['RowTeam']['total'] == 0)
        $this->_sections['RowTeam']['show'] = false;
} else
    $this->_sections['RowTeam']['total'] = 0;
if ($this->_sections['RowTeam']['show']):

            for ($this->_sections['RowTeam']['index'] = $this->_sections['RowTeam']['start'], $this->_sections['RowTeam']['iteration'] = 1;
                 $this->_sections['RowTeam']['iteration'] <= $this->_sections['RowTeam']['total'];
                 $this->_sections['RowTeam']['index'] += $this->_sections['RowTeam']['step'], $this->_sections['RowTeam']['iteration']++):
$this->_sections['RowTeam']['rownum'] = $this->_sections['RowTeam']['iteration'];
$this->_sections['RowTeam']['index_prev'] = $this->_sections['RowTeam']['index'] - $this->_sections['RowTeam']['step'];
$this->_sections['RowTeam']['index_next'] = $this->_sections['RowTeam']['index'] + $this->_sections['RowTeam']['step'];
$this->_sections['RowTeam']['first']      = ($this->_sections['RowTeam']['iteration'] == 1);
$this->_sections['RowTeam']['last']       = ($this->_sections['RowTeam']['iteration'] == $this->_sections['RowTeam']['total']);
?>
			<?php if ($this->_sections['RowTeam']['index']%3 == 0): ?>
			<p class="clear"></p>
			<label>&nbsp;</label>			
			<?php endif; ?>
			<input type="checkbox" class="check" name="submited_team[]"  value="<?php echo $this->_tpl_vars['TeamArr'][$this->_sections['RowTeam']['index']]['team_id']; ?>
" 
<?php if (((is_array($_tmp=$this->_tpl_vars['TeamArr'][$this->_sections['RowTeam']['index']]['team_id'])) ? $this->_run_mod_handler('inarray', true, $_tmp, $this->_tpl_vars['submited_team']) : in_array($_tmp, $this->_tpl_vars['submited_team']))): ?>checked<?php endif; ?> /> 
			<label class="chkoption"><?php echo $this->_tpl_vars['TeamArr'][$this->_sections['RowTeam']['index']]['team_title']; ?>
</label>	
						
			<?php endfor; endif; ?>
			<?php endif; ?>		
		</div>
		
		
		  <div id="type_gap" <?php if ($this->_tpl_vars['FabricArr']['is_type'] != 'Y'): ?> style='display:none' <?php endif; ?>>
			<p class="clear"></p>
		  </div>
		 
		 <div id="type" <?php if ($this->_tpl_vars['FabricArr']['is_type'] != 'Y'): ?> style='display:none' <?php endif; ?>>
			<label>Type:</label>
            <p class="clear"></p>			
			<?php if (count($this->_tpl_vars['TypeArr']) != 0): ?>
		 	<?php unset($this->_sections['RowType']);
$this->_sections['RowType']['name'] = 'RowType';
$this->_sections['RowType']['loop'] = is_array($_loop=$this->_tpl_vars['TypeArr']) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$this->_sections['RowType']['show'] = true;
$this->_sections['RowType']['max'] = $this->_sections['RowType']['loop'];
$this->_sections['RowType']['step'] = 1;
$this->_sections['RowType']['start'] = $this->_sections['RowType']['step'] > 0 ? 0 : $this->_sections['RowType']['loop']-1;
if ($this->_sections['RowType']['show']) {
    $this->_sections['RowType']['total'] = $this->_sections['RowType']['loop'];
    if ($this->_sections['RowType']['total'] == 0)
        $this->_sections['RowType']['show'] = false;
} else
    $this->_sections['RowType']['total'] = 0;
if ($this->_sections['RowType']['show']):

            for ($this->_sections['RowType']['index'] = $this->_sections['RowType']['start'], $this->_sections['RowType']['iteration'] = 1;
                 $this->_sections['RowType']['iteration'] <= $this->_sections['RowType']['total'];
                 $this->_sections['RowType']['index'] += $this->_sections['RowType']['step'], $this->_sections['RowType']['iteration']++):
$this->_sections['RowType']['rownum'] = $this->_sections['RowType']['iteration'];
$this->_sections['RowType']['index_prev'] = $this->_sections['RowType']['index'] - $this->_sections['RowType']['step'];
$this->_sections['RowType']['index_next'] = $this->_sections['RowType']['index'] + $this->_sections['RowType']['step'];
$this->_sections['RowType']['first']      = ($this->_sections['RowType']['iteration'] == 1);
$this->_sections['RowType']['last']       = ($this->_sections['RowType']['iteration'] == $this->_sections['RowType']['total']);
?>
            <?php if ($this->_sections['RowType']['index']%3 == 0): ?>
			<p class="clear"></p>
			<label>&nbsp;</label>
			<?php endif; ?>
			<input type="checkbox" class="check" name="submited_type[]"  value="<?php echo $this->_tpl_vars['TypeArr'][$this->_sections['RowType']['index']]['type_id']; ?>
" 
<?php if (((is_array($_tmp=$this->_tpl_vars['TypeArr'][$this->_sections['RowType']['index']]['type_id'])) ? $this->_run_mod_handler('inarray', true, $_tmp, $this->_tpl_vars['submited_type']) : in_array($_tmp, $this->_tpl_vars['submited_type']))): ?>checked<?php endif; ?> /> 
			<label class="chkoption"><?php echo $this->_tpl_vars['TypeArr'][$this->_sections['RowType']['index']]['type_title'];  echo $this->_sections['RowType']['index']; ?>
</label>		
			<?php endfor; endif; ?>
			<?php endif; ?>			
		</div>
		
		  <div id="champion_gap" <?php if ($this->_tpl_vars['FabricArr']['is_champion'] != 'Y'): ?> style='display:none' <?php endif; ?>>
			<p class="clear"></p>
		  </div>
	
		 <div id="champion" <?php if ($this->_tpl_vars['FabricArr']['is_champion'] != 'Y'): ?> style='display:none' <?php endif; ?>>
			<label>Champion:</label>
            <p class="clear"></p>			
			<?php if (count($this->_tpl_vars['ChampionArr']) != 0): ?>
		 	<?php unset($this->_sections['RowChampion']);
$this->_sections['RowChampion']['name'] = 'RowChampion';
$this->_sections['RowChampion']['loop'] = is_array($_loop=$this->_tpl_vars['ChampionArr']) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$this->_sections['RowChampion']['show'] = true;
$this->_sections['RowChampion']['max'] = $this->_sections['RowChampion']['loop'];
$this->_sections['RowChampion']['step'] = 1;
$this->_sections['RowChampion']['start'] = $this->_sections['RowChampion']['step'] > 0 ? 0 : $this->_sections['RowChampion']['loop']-1;
if ($this->_sections['RowChampion']['show']) {
    $this->_sections['RowChampion']['total'] = $this->_sections['RowChampion']['loop'];
    if ($this->_sections['RowChampion']['total'] == 0)
        $this->_sections['RowChampion']['show'] = false;
} else
    $this->_sections['RowChampion']['total'] = 0;
if ($this->_sections['RowChampion']['show']):

            for ($this->_sections['RowChampion']['index'] = $this->_sections['RowChampion']['start'], $this->_sections['RowChampion']['iteration'] = 1;
                 $this->_sections['RowChampion']['iteration'] <= $this->_sections['RowChampion']['total'];
                 $this->_sections['RowChampion']['index'] += $this->_sections['RowChampion']['step'], $this->_sections['RowChampion']['iteration']++):
$this->_sections['RowChampion']['rownum'] = $this->_sections['RowChampion']['iteration'];
$this->_sections['RowChampion']['index_prev'] = $this->_sections['RowChampion']['index'] - $this->_sections['RowChampion']['step'];
$this->_sections['RowChampion']['index_next'] = $this->_sections['RowChampion']['index'] + $this->_sections['RowChampion']['step'];
$this->_sections['RowChampion']['first']      = ($this->_sections['RowChampion']['iteration'] == 1);
$this->_sections['RowChampion']['last']       = ($this->_sections['RowChampion']['iteration'] == $this->_sections['RowChampion']['total']);
?>
			<?php if ($this->_sections['RowChampion']['index']%3 == 0): ?>
			<p class="clear"></p>
			<label>&nbsp;</label>
			<?php endif; ?>
			<input type="checkbox" class="check" name="submited_champion[]"  value="<?php echo $this->_tpl_vars['ChampionArr'][$this->_sections['RowChampion']['index']]['champion_id']; ?>
" 
<?php if (((is_array($_tmp=$this->_tpl_vars['ChampionArr'][$this->_sections['RowChampion']['index']]['champion_id'])) ? $this->_run_mod_handler('inarray', true, $_tmp, $this->_tpl_vars['submited_champion']) : in_array($_tmp, $this->_tpl_vars['submited_champion']))): ?>checked<?php endif; ?> /> 
			<label class="chkoption"><?php echo $this->_tpl_vars['ChampionArr'][$this->_sections['RowChampion']['index']]['champion_title']; ?>
	</label>	
			<?php endfor; endif; ?>
			<?php endif; ?>			
		</div>
		
		 <div id="class_gap" <?php if ($this->_tpl_vars['FabricArr']['is_class'] != 'Y'): ?> style='display:none' <?php endif; ?>>
			<p class="clear"></p>
		  </div>
	
		 <div id="class" <?php if ($this->_tpl_vars['FabricArr']['is_class'] != 'Y'): ?> style='display:none' <?php endif; ?>>
			<label>Class:</label>			
			<?php if (count($this->_tpl_vars['ClassArr']) != 0): ?>
		 	<?php unset($this->_sections['RowClass']);
$this->_sections['RowClass']['name'] = 'RowClass';
$this->_sections['RowClass']['loop'] = is_array($_loop=$this->_tpl_vars['ClassArr']) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$this->_sections['RowClass']['show'] = true;
$this->_sections['RowClass']['max'] = $this->_sections['RowClass']['loop'];
$this->_sections['RowClass']['step'] = 1;
$this->_sections['RowClass']['start'] = $this->_sections['RowClass']['step'] > 0 ? 0 : $this->_sections['RowClass']['loop']-1;
if ($this->_sections['RowClass']['show']) {
    $this->_sections['RowClass']['total'] = $this->_sections['RowClass']['loop'];
    if ($this->_sections['RowClass']['total'] == 0)
        $this->_sections['RowClass']['show'] = false;
} else
    $this->_sections['RowClass']['total'] = 0;
if ($this->_sections['RowClass']['show']):

            for ($this->_sections['RowClass']['index'] = $this->_sections['RowClass']['start'], $this->_sections['RowClass']['iteration'] = 1;
                 $this->_sections['RowClass']['iteration'] <= $this->_sections['RowClass']['total'];
                 $this->_sections['RowClass']['index'] += $this->_sections['RowClass']['step'], $this->_sections['RowClass']['iteration']++):
$this->_sections['RowClass']['rownum'] = $this->_sections['RowClass']['iteration'];
$this->_sections['RowClass']['index_prev'] = $this->_sections['RowClass']['index'] - $this->_sections['RowClass']['step'];
$this->_sections['RowClass']['index_next'] = $this->_sections['RowClass']['index'] + $this->_sections['RowClass']['step'];
$this->_sections['RowClass']['first']      = ($this->_sections['RowClass']['iteration'] == 1);
$this->_sections['RowClass']['last']       = ($this->_sections['RowClass']['iteration'] == $this->_sections['RowClass']['total']);
?>
			<?php if ($this->_sections['RowClass']['index']%3 == 0): ?>
			<p class="clear"></p>
			<label>&nbsp;</label>
			<?php endif; ?>
			<input type="checkbox" class="check" name="submited_class[]"  value="<?php echo $this->_tpl_vars['ClassArr'][$this->_sections['RowClass']['index']]['class_id']; ?>
" 
<?php if (((is_array($_tmp=$this->_tpl_vars['ClassArr'][$this->_sections['RowClass']['index']]['class_id'])) ? $this->_run_mod_handler('inarray', true, $_tmp, $this->_tpl_vars['submited_class']) : in_array($_tmp, $this->_tpl_vars['submited_class']))): ?>checked<?php endif; ?> /> 
			<label class="chkoption"><?php echo $this->_tpl_vars['ClassArr'][$this->_sections['RowClass']['index']]['class_title']; ?>
</label>			
			<?php endfor; endif; ?>
			<?php endif; ?>	
		</div>
		
		 <div id="map_gap" <?php if ($this->_tpl_vars['FabricArr']['is_map'] != 'Y'): ?> style='display:none' <?php endif; ?>>
			<p class="clear"></p>
		  </div>
	
		 <div id="map" <?php if ($this->_tpl_vars['FabricArr']['is_map'] != 'Y'): ?> style='display:none' <?php endif; ?>>
		<label>Map:</label>
        <p class="clear"></p>		
			<?php if (count($this->_tpl_vars['MapArr']) != 0): ?>
		 	<?php unset($this->_sections['RowMap']);
$this->_sections['RowMap']['name'] = 'RowMap';
$this->_sections['RowMap']['loop'] = is_array($_loop=$this->_tpl_vars['MapArr']) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$this->_sections['RowMap']['show'] = true;
$this->_sections['RowMap']['max'] = $this->_sections['RowMap']['loop'];
$this->_sections['RowMap']['step'] = 1;
$this->_sections['RowMap']['start'] = $this->_sections['RowMap']['step'] > 0 ? 0 : $this->_sections['RowMap']['loop']-1;
if ($this->_sections['RowMap']['show']) {
    $this->_sections['RowMap']['total'] = $this->_sections['RowMap']['loop'];
    if ($this->_sections['RowMap']['total'] == 0)
        $this->_sections['RowMap']['show'] = false;
} else
    $this->_sections['RowMap']['total'] = 0;
if ($this->_sections['RowMap']['show']):

            for ($this->_sections['RowMap']['index'] = $this->_sections['RowMap']['start'], $this->_sections['RowMap']['iteration'] = 1;
                 $this->_sections['RowMap']['iteration'] <= $this->_sections['RowMap']['total'];
                 $this->_sections['RowMap']['index'] += $this->_sections['RowMap']['step'], $this->_sections['RowMap']['iteration']++):
$this->_sections['RowMap']['rownum'] = $this->_sections['RowMap']['iteration'];
$this->_sections['RowMap']['index_prev'] = $this->_sections['RowMap']['index'] - $this->_sections['RowMap']['step'];
$this->_sections['RowMap']['index_next'] = $this->_sections['RowMap']['index'] + $this->_sections['RowMap']['step'];
$this->_sections['RowMap']['first']      = ($this->_sections['RowMap']['iteration'] == 1);
$this->_sections['RowMap']['last']       = ($this->_sections['RowMap']['iteration'] == $this->_sections['RowMap']['total']);
?>
			<?php if ($this->_sections['RowMap']['index']%3 == 0): ?>
			<p class="clear"></p>
			<label>&nbsp;</label>
			<?php endif; ?>
			<input type="checkbox" class="check" name="submited_map[]"  value="<?php echo $this->_tpl_vars['MapArr'][$this->_sections['RowMap']['index']]['map_id']; ?>
" 
<?php if (((is_array($_tmp=$this->_tpl_vars['MapArr'][$this->_sections['RowMap']['index']]['map_id'])) ? $this->_run_mod_handler('inarray', true, $_tmp, $this->_tpl_vars['submited_map']) : in_array($_tmp, $this->_tpl_vars['submited_map']))): ?>checked<?php endif; ?> /> 
			<label class="chkoption"><?php echo $this->_tpl_vars['MapArr'][$this->_sections['RowMap']['index']]['map_title']; ?>
</label>			
			<?php endfor; endif; ?>
			<?php endif; ?>				
		</div>
		
		 <div id="mode_gap" <?php if ($this->_tpl_vars['FabricArr']['is_mode'] != 'Y'): ?> style='display:none' <?php endif; ?>>
			<p class="clear"></p>
		  </div>
	
		 <div id="mode" <?php if ($this->_tpl_vars['FabricArr']['is_mode'] != 'Y'): ?> style='display:none' <?php endif; ?>>
		<label>Mode:</label>				
			<?php if (count($this->_tpl_vars['ModeArr']) != 0): ?>
		 	<?php unset($this->_sections['RowMode']);
$this->_sections['RowMode']['name'] = 'RowMode';
$this->_sections['RowMode']['loop'] = is_array($_loop=$this->_tpl_vars['ModeArr']) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$this->_sections['RowMode']['show'] = true;
$this->_sections['RowMode']['max'] = $this->_sections['RowMode']['loop'];
$this->_sections['RowMode']['step'] = 1;
$this->_sections['RowMode']['start'] = $this->_sections['RowMode']['step'] > 0 ? 0 : $this->_sections['RowMode']['loop']-1;
if ($this->_sections['RowMode']['show']) {
    $this->_sections['RowMode']['total'] = $this->_sections['RowMode']['loop'];
    if ($this->_sections['RowMode']['total'] == 0)
        $this->_sections['RowMode']['show'] = false;
} else
    $this->_sections['RowMode']['total'] = 0;
if ($this->_sections['RowMode']['show']):

            for ($this->_sections['RowMode']['index'] = $this->_sections['RowMode']['start'], $this->_sections['RowMode']['iteration'] = 1;
                 $this->_sections['RowMode']['iteration'] <= $this->_sections['RowMode']['total'];
                 $this->_sections['RowMode']['index'] += $this->_sections['RowMode']['step'], $this->_sections['RowMode']['iteration']++):
$this->_sections['RowMode']['rownum'] = $this->_sections['RowMode']['iteration'];
$this->_sections['RowMode']['index_prev'] = $this->_sections['RowMode']['index'] - $this->_sections['RowMode']['step'];
$this->_sections['RowMode']['index_next'] = $this->_sections['RowMode']['index'] + $this->_sections['RowMode']['step'];
$this->_sections['RowMode']['first']      = ($this->_sections['RowMode']['iteration'] == 1);
$this->_sections['RowMode']['last']       = ($this->_sections['RowMode']['iteration'] == $this->_sections['RowMode']['total']);
?>
			<?php if ($this->_sections['RowMode']['index']%3 == 0): ?>
			<p class="clear"></p>
			<label>&nbsp;</label>
			<?php endif; ?>
			<input type="checkbox" class="check" name="submited_mode[]"  value="<?php echo $this->_tpl_vars['ModeArr'][$this->_sections['RowMode']['index']]['mode_id']; ?>
" 
<?php if (((is_array($_tmp=$this->_tpl_vars['ModeArr'][$this->_sections['RowMode']['index']]['mode_id'])) ? $this->_run_mod_handler('inarray', true, $_tmp, $this->_tpl_vars['submited_mode']) : in_array($_tmp, $this->_tpl_vars['submited_mode']))): ?>checked<?php endif; ?> /> 
			<label class="chkoption"><?php echo $this->_tpl_vars['ModeArr'][$this->_sections['RowMode']['index']]['mode_title']; ?>
	</label>	
			<?php endfor; endif; ?>
			<?php endif; ?>			
		</div>
		<p class="clear"></p>	
			
        <!--<label>Select Race :</label>
            <span id="race_id_td">
			<select name="race_id" id="race_id" class="con-req">
					<option value="">Select</option>
			</select>
			</span>
            <p class="clear"></p>
            <label>Select Ladder :</label>
			<span id="ladder_id_td">
            <select name="ladder_id" id="ladder_id" class="con-req">
					<option value="">Select</option>
			</select>
			</span>-->
			 <label>Video Type :</label>
            <select name="is_video_url" id="is_video_url">
			<option value='Y' <?php if ($this->_tpl_vars['Formval']['is_video_url'] == 'Y'): ?>selected<?php endif; ?>> URL</option>
			<option value='N' <?php if ($this->_tpl_vars['Formval']['is_video_url'] == 'N'): ?>selected<?php endif; ?>>Upload Video</option>
			</select>
			<p class="clear"></p>
			<label>Youtube Url :</label>
            <input name="video_url" id="video_url" type="text" value="<?php echo $this->_tpl_vars['Formval']['video_url']; ?>
" />
			<label>Time length (min):</label>
            <input name="time_length" id="time_length" type="text" value="<?php echo $this->_tpl_vars['Formval']['time_length']; ?>
" class="con-req small" onkeypress="return keyCheck(event, this);" />&nbsp;
			[mm.ss]
            <p class="clear"></p>
			<div style="padding-top:0px;padding-bottom:20px; padding-left:30px; font-size:12px;">[i.e http://www.youtube.com/watch?v=Di7G4nbpyDg]</div>
			<p class="clear"></p>
			<?php echo $this->_tpl_vars['DisplayVideoControlStr']; ?>

			<?php echo $this->_tpl_vars['DisplayImageControlStr']; ?>

			
			<label>Description :</label>
            <textarea  name="description" id="description"><?php echo $this->_tpl_vars['Formval']['description']; ?>
</textarea>
            <p class="clear"></p>
           
            <label>&nbsp;</label>
            <input name="submit" class="submit" value="<?php echo $this->_tpl_vars['SubmitButton']; ?>
" type="submit" onclick='return CheckFields()' />
            <input name="" class="cancel" value="Cancel" type="button" onclick="window.location.href='upload_videos.php'" />
         </fieldset>
      </form>
      </div>
      
     </div>
     </div>
    </div>